/*
 /*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */

/*
 * ClerkManagement.java
 *
 * Created on 2011-10-20, 19:52:59
 */
package JavaApplication1;

/**
 *
 * @author mengqingyi
 */
public class ClerkManagement extends javax.swing.JFrame {

    /** Creates new form ClerkManagement */
    public ClerkManagement() {
        initComponents();
    }
 // Variables declaration - do not modify//GEN-BEGIN:variables
    private javax.swing.JRadioButton add;
    private javax.swing.JRadioButton change_position;
    private javax.swing.JRadioButton off_job;
    
    private javax.swing.JPanel basePanel;
    private javax.swing.JPanel opreationChoicePanel;
    
    private javax.swing.JScrollPane clerkIDInputPanel;
    private javax.swing.JScrollPane clerkInfoPanel;
    private javax.swing.JScrollPane changePositionInput;
    
    private javax.swing.JTextField clerkIDPanel;
    
    private javax.swing.JTextPane changePositionText;
    private javax.swing.JTextPane clerkIDText;
    
    private javax.swing.JLabel operationChoiceLabel;
    
    private javax.swing.JList clerkInfoList;
    
    private javax.swing.JButton showClerkInfo;
    private javax.swing.JButton yes;
    private javax.swing.JButton cancel;
    // End of variables declaration//GEN-END:variables

    
    /** This method is called from within the constructor to
     * initialize the form.
     * WARNING: Do NOT modify this code. The content of this method is
     * always regenerated by the Form Editor.
     */
    
    @SuppressWarnings("unchecked")
    // <editor-fold defaultstate="collapsed" desc="Generated Code">//GEN-BEGIN:initComponents
    private void initComponents() {

    	add = new javax.swing.JRadioButton();
    	change_position = new javax.swing.JRadioButton();
    	off_job = new javax.swing.JRadioButton();
    	
        basePanel = new javax.swing.JPanel();
        opreationChoicePanel = new javax.swing.JPanel();
        
        clerkIDInputPanel = new javax.swing.JScrollPane();
        changePositionInput = new javax.swing.JScrollPane();
        clerkInfoPanel = new javax.swing.JScrollPane();
        
        clerkIDPanel = new javax.swing.JTextField();
        
        clerkIDText = new javax.swing.JTextPane();
        changePositionText = new javax.swing.JTextPane();
        
        operationChoiceLabel = new javax.swing.JLabel();
        
        clerkInfoList = new javax.swing.JList();
        
        yes = new javax.swing.JButton();
        cancel = new javax.swing.JButton();
        showClerkInfo = new javax.swing.JButton();
        
        
        setDefaultCloseOperation(javax.swing.WindowConstants.EXIT_ON_CLOSE);
        setTitle("用户管理");

        basePanel.setBackground(new java.awt.Color(211, 220, 249));

        clerkIDPanel.setBackground(new java.awt.Color(211, 220, 249));
        clerkIDPanel.setFont(new java.awt.Font("华文彩云", 0, 18));
        clerkIDPanel.setText("请输入员工编号");

        clerkIDText.setBorder(new javax.swing.border.SoftBevelBorder(javax.swing.border.BevelBorder.RAISED));
        clerkIDInputPanel.setViewportView(clerkIDText);

        yes.setText("确定");

        cancel.setText("取消");

        showClerkInfo.setText("显示员工信息");
        showClerkInfo.setActionCommand("");

        opreationChoicePanel.setBackground(new java.awt.Color(211, 220, 249));
        opreationChoicePanel.setBorder(javax.swing.BorderFactory.createBevelBorder(javax.swing.border.BevelBorder.RAISED));

        operationChoiceLabel.setFont(new java.awt.Font("华文仿宋", 0, 18));
        operationChoiceLabel.setText("操作选项");

        off_job.setBackground(new java.awt.Color(211, 220, 249));
        off_job.setText("离职");
        off_job.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                off_jobActionPerformed(evt);
            }
        });

        change_position.setBackground(new java.awt.Color(211, 220, 249));
        change_position.setText("职位变更至：");
        change_position.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                change_positionActionPerformed(evt);
            }
        });

        changePositionText.setBorder(new javax.swing.border.SoftBevelBorder(javax.swing.border.BevelBorder.RAISED));
        changePositionInput.setViewportView(changePositionText);

        add.setBackground(new java.awt.Color(211, 220, 249));
        add.setText("新增");
        add.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                addActionPerformed(evt);
            }
        });

        javax.swing.GroupLayout opreationChoicePanelLayout = new javax.swing.GroupLayout(opreationChoicePanel);
        opreationChoicePanel.setLayout(opreationChoicePanelLayout);
        opreationChoicePanelLayout.setHorizontalGroup(
            opreationChoicePanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(opreationChoicePanelLayout.createSequentialGroup()
                .addGroup(opreationChoicePanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                    .addGroup(opreationChoicePanelLayout.createSequentialGroup()
                        .addGap(31, 31, 31)
                        .addComponent(operationChoiceLabel))
                    .addGroup(opreationChoicePanelLayout.createSequentialGroup()
                        .addGap(18, 18, 18)
                        .addGroup(opreationChoicePanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                            .addGroup(opreationChoicePanelLayout.createSequentialGroup()
                                .addComponent(change_position)
                                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)
                                .addComponent(changePositionInput, javax.swing.GroupLayout.PREFERRED_SIZE, 113, javax.swing.GroupLayout.PREFERRED_SIZE))
                            .addComponent(off_job)
                            .addComponent(add))))
                .addContainerGap(80, Short.MAX_VALUE))
        );
        
        opreationChoicePanelLayout.setVerticalGroup(
            opreationChoicePanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(opreationChoicePanelLayout.createSequentialGroup()
                .addContainerGap()
                .addComponent(operationChoiceLabel)
                .addGap(18, 18, 18)
                .addComponent(off_job)
                .addGap(17, 17, 17)
                .addComponent(add)
                .addGap(18, 18, 18)
                .addGroup(opreationChoicePanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.TRAILING)
                    .addComponent(change_position)
                    .addComponent(changePositionInput, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
                .addContainerGap(40, Short.MAX_VALUE))
        );

        clerkInfoList.setBackground(javax.swing.UIManager.getDefaults().getColor("inactiveCaption"));
        clerkInfoList.setBorder(javax.swing.BorderFactory.createTitledBorder(new javax.swing.border.SoftBevelBorder(javax.swing.border.BevelBorder.RAISED), "员工基本信息", javax.swing.border.TitledBorder.DEFAULT_JUSTIFICATION, javax.swing.border.TitledBorder.DEFAULT_POSITION, new java.awt.Font("方正舒体", 0, 14), new java.awt.Color(9, 9, 112))); // NOI18N
        clerkInfoList.setModel(new javax.swing.AbstractListModel() {
            String[] strings = { "工号：    ", "姓名：    ", "性别：    ", "籍贯：    ", "出生日期：", "职位：    ", "上岗日期：", "离职日期：", "工资待遇：", "工作时长：" };
            public int getSize() { return strings.length; }
            public Object getElementAt(int i) { return strings[i]; }
        });
        clerkInfoPanel.setViewportView(clerkInfoList);

        javax.swing.GroupLayout basePanelLayout = new javax.swing.GroupLayout(basePanel);
        basePanel.setLayout(basePanelLayout);
        basePanelLayout.setHorizontalGroup(
            basePanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(basePanelLayout.createSequentialGroup()
                .addGroup(basePanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                    .addGroup(basePanelLayout.createSequentialGroup()
                        .addGap(34, 34, 34)
                        .addGroup(basePanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                            .addComponent(clerkIDPanel, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                            .addGroup(basePanelLayout.createSequentialGroup()
                                .addComponent(clerkIDInputPanel, javax.swing.GroupLayout.PREFERRED_SIZE, 187, javax.swing.GroupLayout.PREFERRED_SIZE)
                                .addGap(18, 18, 18)
                                .addComponent(showClerkInfo))
                            .addGroup(basePanelLayout.createSequentialGroup()
                                .addComponent(opreationChoicePanel, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                                .addGap(69, 69, 69)
                                .addComponent(clerkInfoPanel, javax.swing.GroupLayout.PREFERRED_SIZE, 172, javax.swing.GroupLayout.PREFERRED_SIZE))))
                    .addGroup(basePanelLayout.createSequentialGroup()
                        .addGap(182, 182, 182)
                        .addComponent(yes)
                        .addGap(126, 126, 126)
                        .addComponent(cancel)))
                .addGap(80, 80, 80))
        );
        basePanelLayout.setVerticalGroup(
            basePanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(basePanelLayout.createSequentialGroup()
                .addGroup(basePanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.TRAILING, false)
                    .addGroup(javax.swing.GroupLayout.Alignment.LEADING, basePanelLayout.createSequentialGroup()
                        .addGap(119, 119, 119)
                        .addComponent(clerkInfoPanel))
                    .addGroup(javax.swing.GroupLayout.Alignment.LEADING, basePanelLayout.createSequentialGroup()
                        .addGap(50, 50, 50)
                        .addComponent(clerkIDPanel, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                        .addGap(18, 18, 18)
                        .addGroup(basePanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                            .addComponent(clerkIDInputPanel, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                            .addComponent(showClerkInfo))
                        .addGap(33, 33, 33)
                        .addComponent(opreationChoicePanel, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)))
                .addGap(53, 53, 53)
                .addGroup(basePanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(yes)
                    .addComponent(cancel))
                .addContainerGap(48, Short.MAX_VALUE))
        );

        javax.swing.GroupLayout layout = new javax.swing.GroupLayout(getContentPane());
        getContentPane().setLayout(layout);
        layout.setHorizontalGroup(
            layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addComponent(basePanel, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
        );
        layout.setVerticalGroup(
            layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addComponent(basePanel, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
        );

        pack();
    }// </editor-fold>//GEN-END:initComponents

private void off_jobActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_off_jobActionPerformed
// TODO add your handling code here:
}//GEN-LAST:event_off_jobActionPerformed

private void change_positionActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_change_positionActionPerformed
// TODO add your handling code here:
}//GEN-LAST:event_change_positionActionPerformed

private void addActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_addActionPerformed
// TODO add your handling code here:
}//GEN-LAST:event_addActionPerformed

    /**
     * @param args the command line arguments
     */
    public static void main(String args[]) {
        /* Set the Nimbus look and feel */
        //<editor-fold defaultstate="collapsed" desc=" Look and feel setting code (optional) ">
        /* If Nimbus (introduced in Java SE 6) is not available, stay with the default look and feel.
         * For details see http://download.oracle.com/javase/tutorial/uiswing/lookandfeel/plaf.html 
         */
        try {
            for (javax.swing.UIManager.LookAndFeelInfo info : javax.swing.UIManager.getInstalledLookAndFeels()) {
                if ("Nimbus".equals(info.getName())) {
                    javax.swing.UIManager.setLookAndFeel(info.getClassName());
                    break;
                }
            }
        } catch (ClassNotFoundException ex) {
            java.util.logging.Logger.getLogger(ClerkManagement.class.getName()).log(java.util.logging.Level.SEVERE, null, ex);
        } catch (InstantiationException ex) {
            java.util.logging.Logger.getLogger(ClerkManagement.class.getName()).log(java.util.logging.Level.SEVERE, null, ex);
        } catch (IllegalAccessException ex) {
            java.util.logging.Logger.getLogger(ClerkManagement.class.getName()).log(java.util.logging.Level.SEVERE, null, ex);
        } catch (javax.swing.UnsupportedLookAndFeelException ex) {
            java.util.logging.Logger.getLogger(ClerkManagement.class.getName()).log(java.util.logging.Level.SEVERE, null, ex);
        }
        //</editor-fold>

        /* Create and display the form */
        java.awt.EventQueue.invokeLater(new Runnable() {

            public void run() {
                new ClerkManagement().setVisible(true);
            }
        });
    }
}
